<!DOCTYPE html>
<html lang="zh-CN">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>前端监控</title>
    <script src="https://unpkg.com/axios@0.19.0/dist/axios.min.js"></script>
</head>

<body>
    <script>
        unReport.init({
            time: 3000,
            callback: (data) => {
                // new Image().src = 'http://localhost:3000/test1?' + JSON.stringify(data);
                console.log(data);
            }
        });
    </script>
    <link rel="stylesheet" href="./style.css">
    <h1>请打开 控制台查看信息</h1>

    <!-- 不存在此图片 只是测试异常监听 -->
    <img src="./example.png" alt="">
    <!-- 不存在此文件 只是测试异常监听 -->
    <script src="./example.js"></script>

    <script>
        // 测试
        setTimeout(() => {
            let el = document.createElement('img');
            // 不存在此图片 只是测试异常监听
            el.setAttribute('src', './example.png');
            document.body.append(el);
            // 不存在此接口 只是测试异常监听
            axios.get('http://localhost:3000/test').then(res => {
                console.log(res)
            })
        }, 5000)

        console.log(example)
    </script>
</body>

</html>